<?php echo $this->element('banner');?>
<div class="container prd-category">
    <div class="row" id="sub-page">
        <div class="col-lg-8">
            <h2><?php echo $categoryName['ProductCategory']['name' . $code]?></h2>
			<div class="row">
            <?php 
            foreach($products as $key=>$product) :
                if($key && $key % 4 == 0) :
                    echo '</div>';
                    echo '<div class="row">';
                endif;
            ?>
                <div class="col-lg-3 home-product gallery-row">
                    <div class="product-list product-small">
                        <a href="/products/detail/<?php echo $product['Product']['product_id']?>">
                            <img width="145" height="120" src="/files/images/<?php echo $product['Product']['image']?>">
                            <div class="pd-title">
                                <h5><?php echo @$product['Product']['name' . $code]?></h5>
                                <span><?php echo __('Product code').': ' . @$product['Product']['code']?></span>
                            </div>
                        </a>
                    </div>        	
                </div>
            <?php endforeach;?>
            </div>
            <?php if($this->Paginator->counter('{:pages}') > 1) :?>
            <nav>
                <div class="pagination">
                <?php
                    echo $this->Paginator->prev('&laquo; ', array('escape' => false,'tag' => 'li'), '&laquo; ', array('escape' => false, 'tag' => 'span'));
                    echo $this->Paginator->numbers(array('separator' => '', 'tag' => 'li', 'currentTag' => 'span', 'currentClass' => 'active'));
                    echo $this->Paginator->next(' &raquo;', array('tag' => 'li', 'escape' => false), ' &raquo;', array('tag' => 'span', 'escape' => false));
                ?>
                </div>
            </nav>
            <?php endif;?>
            
            <h3><?php echo $article['ProductIntro']['name' . $code]?></h3>
            <div class="content">
                <?php echo $article['ProductIntro']['description' . $code]?>                
            </div>
        </div>
        
        <?php echo $this->element('Product/category');?>		
    </div>
</div>

<?php echo $this->element('Product/product_category');?>	

<?php echo $this->element('partner');?>